package com.axc.gallery2.net;

import android.os.Bundle;

import com.renren.api.connect.android.common.RequestParam;
import com.renren.api.connect.android.exception.RenrenException;

/**
 * 封装photos.get API请求的所需参数类
 */
public class PhotosGetRequestParam  extends RequestParam{
    
    /**
     * 调用获取相册API传入的method参数，必须参数
     */
    private static final String METHOD = "photos.get";
    
    /**
     * 照片pid
     */
    private long pid;
    /**
     * 照片所属相册aid,必须参数
     */
    private long aid;
    /**
     * 照片所有者uid
     */
    private long uid;
    /**
     * 正常尺寸照片源url
     */
    private String url_head;
    /**
     * 小尺寸照片源url
     */
    private String url_tiny;
    /**
     * 大尺寸照片源url
     */
    private String url_large;
    /**
     * 照片描述
     */
    private String caption;
    
    public PhotosGetRequestParam(){
        
    }
    public PhotosGetRequestParam(long aid){
        this.aid = aid;
    }
    
    public long getPid() {
        return pid;
    }

    public void setPid(long pid) {
        this.pid = pid;
    }

    public long getAid() {
        return aid;
    }

    public void setAid(long aid) {
        this.aid = aid;
    }

    public long getUid() {
        return uid;
    }

    public void setUid(long uid) {
        this.uid = uid;
    }

    public String getUrl_head() {
        return url_head;
    }

    public void setUrl_head(String urlHead) {
        url_head = urlHead;
    }

    public String getUrl_tiny() {
        return url_tiny;
    }

    public void setUrl_tiny(String urlTiny) {
        url_tiny = urlTiny;
    }

    public String getUrl_large() {
        return url_large;
    }

    public void setUrl_large(String urlLarge) {
        url_large = urlLarge;
    }

    public String getCaption() {
        return caption;
    }

    public void setCaption(String caption) {
        this.caption = caption;
    }

    @Override
    public Bundle getParams() throws RenrenException {
        Bundle params = new Bundle();
        params.putString("method", METHOD);
        // 默认请求返回参数为json格式，不提供设置此值的接口给用户
        //params.putString("format", Renren.RESPONSE_FORMAT_JSON);
        params.putString("uid", String.valueOf(this.uid));
        params.putString("aid", String.valueOf(this.aid));
        return params;
    }

}
